Integrand size = 26, antiderivative size = 101 \[ \int (a+a \sec (e+f x))^3 (c-c \sec (e+f x))^n \, dx=\frac {2^{\frac {1}{2}+n} c \operatorname {AppellF1}\left (\frac {7}{2},\frac {1}{2}-n,1,\frac {9}{2},\frac {1}{2} (1+\sec (e+f x)),1+\sec (e+f x)\right ) (1-\sec (e+f x))^{\frac {1}{2}-n} (a+a \sec (e+f x))^3 (c-c \sec (e+f x))^{-1+n} \tan (e+f x)}{7 f} \]
1/7*2^(1/2+n)*c*AppellF1(7/2,1,1/2-n,9/2,1+sec(f*x+e),1/2+1/2*sec(f*x+e))* (1-sec(f*x+e))^(1/2-n)*(a+a*sec(f*x+e))^3*(c-c*sec(f*x+e))^(-1+n)*tan(f*x+ e)/f
\[ \int (a+a \sec (e+f x))^3 (c-c \sec (e+f x))^n \, dx=\int (a+a \sec (e+f x))^3 (c-c \sec (e+f x))^n \, dx \]
Time = 0.30 (sec) , antiderivative size = 101, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.154, Rules used = {3042, 4400, 154, 153}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int (a \sec (e+f x)+a)^3 (c-c \sec (e+f x))^n \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \left (a \csc \left (e+f x+\frac {\pi }{2}\right )+a\right )^3 \left (c-c \csc \left (e+f x+\frac {\pi }{2}\right )\right )^ndx\) |
\(\Big \downarrow \) 4400 |
\(\displaystyle -\frac {a c \tan (e+f x) \int \cos (e+f x) (\sec (e+f x) a+a)^{5/2} (c-c \sec (e+f x))^{n-\frac {1}{2}}d\sec (e+f x)}{f \sqrt {a \sec (e+f x)+a} \sqrt {c-c \sec (e+f x)}}\) |
\(\Big \downarrow \) 154 |
\(\displaystyle -\frac {a c 2^{n-\frac {1}{2}} \tan (e+f x) (1-\sec (e+f x))^{\frac {1}{2}-n} (c-c \sec (e+f x))^{n-1} \int \cos (e+f x) \left (\frac {1}{2}-\frac {1}{2} \sec (e+f x)\right )^{n-\frac {1}{2}} (\sec (e+f x) a+a)^{5/2}d\sec (e+f x)}{f \sqrt {a \sec (e+f x)+a}}\) |
\(\Big \downarrow \) 153 |
\(\displaystyle \frac {c 2^{n+\frac {1}{2}} \tan (e+f x) (a \sec (e+f x)+a)^3 (1-\sec (e+f x))^{\frac {1}{2}-n} \operatorname {AppellF1}\left (\frac {7}{2},\frac {1}{2}-n,1,\frac {9}{2},\frac {1}{2} (\sec (e+f x)+1),\sec (e+f x)+1\right ) (c-c \sec (e+f x))^{n-1}}{7 f}\) |
(2^(1/2 + n)*c*AppellF1[7/2, 1/2 - n, 1, 9/2, (1 + Sec[e + f*x])/2, 1 + Se c[e + f*x]]*(1 - Sec[e + f*x])^(1/2 - n)*(a + a*Sec[e + f*x])^3*(c - c*Sec [e + f*x])^(-1 + n)*Tan[e + f*x])/(7*f)
3.2.33.3.1 Defintions of rubi rules used
Int[((a_) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_)) ^(p_), x_] :> Simp[(b*e - a*f)^p*((a + b*x)^(m + 1)/(b^(p + 1)*(m + 1)*Simp lify[b/(b*c - a*d)]^n))*AppellF1[m + 1, -n, -p, m + 2, (-d)*((a + b*x)/(b*c - a*d)), (-f)*((a + b*x)/(b*e - a*f))], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && !IntegerQ[m] && !IntegerQ[n] && IntegerQ[p] && GtQ[Simplify[b/( b*c - a*d)], 0] && !(GtQ[Simplify[d/(d*a - c*b)], 0] && SimplerQ[c + d*x, a + b*x])
Int[((a_) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_)) ^(p_), x_] :> Simp[(c + d*x)^FracPart[n]/(Simplify[b/(b*c - a*d)]^IntPart[n ]*(b*((c + d*x)/(b*c - a*d)))^FracPart[n]) Int[(a + b*x)^m*Simp[b*(c/(b*c - a*d)) + b*d*(x/(b*c - a*d)), x]^n*(e + f*x)^p, x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && !IntegerQ[m] && !IntegerQ[n] && IntegerQ[p] && !G tQ[Simplify[b/(b*c - a*d)], 0] && !SimplerQ[c + d*x, a + b*x]
Int[(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_.)*(csc[(e_.) + (f_.)*(x_)]*( d_.) + (c_))^(n_.), x_Symbol] :> Simp[a*c*(Cot[e + f*x]/(f*Sqrt[a + b*Csc[e + f*x]]*Sqrt[c + d*Csc[e + f*x]])) Subst[Int[(a + b*x)^(m - 1/2)*((c + d *x)^(n - 1/2)/x), x], x, Csc[e + f*x]], x] /; FreeQ[{a, b, c, d, e, f, m, n }, x] && EqQ[b*c + a*d, 0] && EqQ[a^2 - b^2, 0]
\[\int \left (a +a \sec \left (f x +e \right )\right )^{3} \left (c -c \sec \left (f x +e \right )\right )^{n}d x\]
\[ \int (a+a \sec (e+f x))^3 (c-c \sec (e+f x))^n \, dx=\int { {\left (a \sec \left (f x + e\right ) + a\right )}^{3} {\left (-c \sec \left (f x + e\right ) + c\right )}^{n} \,d x } \]
integral((a^3*sec(f*x + e)^3 + 3*a^3*sec(f*x + e)^2 + 3*a^3*sec(f*x + e) + a^3)*(-c*sec(f*x + e) + c)^n, x)
\[ \int (a+a \sec (e+f x))^3 (c-c \sec (e+f x))^n \, dx=a^{3} \left (\int 3 \left (- c \sec {\left (e + f x \right )} + c\right )^{n} \sec {\left (e + f x \right )}\, dx + \int 3 \left (- c \sec {\left (e + f x \right )} + c\right )^{n} \sec ^{2}{\left (e + f x \right )}\, dx + \int \left (- c \sec {\left (e + f x \right )} + c\right )^{n} \sec ^{3}{\left (e + f x \right )}\, dx + \int \left (- c \sec {\left (e + f x \right )} + c\right )^{n}\, dx\right ) \]
a**3*(Integral(3*(-c*sec(e + f*x) + c)**n*sec(e + f*x), x) + Integral(3*(- c*sec(e + f*x) + c)**n*sec(e + f*x)**2, x) + Integral((-c*sec(e + f*x) + c )**n*sec(e + f*x)**3, x) + Integral((-c*sec(e + f*x) + c)**n, x))
\[ \int (a+a \sec (e+f x))^3 (c-c \sec (e+f x))^n \, dx=\int { {\left (a \sec \left (f x + e\right ) + a\right )}^{3} {\left (-c \sec \left (f x + e\right ) + c\right )}^{n} \,d x } \]
\[ \int (a+a \sec (e+f x))^3 (c-c \sec (e+f x))^n \, dx=\int { {\left (a \sec \left (f x + e\right ) + a\right )}^{3} {\left (-c \sec \left (f x + e\right ) + c\right )}^{n} \,d x } \]
Timed out. \[ \int (a+a \sec (e+f x))^3 (c-c \sec (e+f x))^n \, dx=\int {\left (a+\frac {a}{\cos \left (e+f\,x\right )}\right )}^3\,{\left (c-\frac {c}{\cos \left (e+f\,x\right )}\right )}^n \,d x \]